package com.qujia.station.mapper;

import com.qujia.common.core.domain.AjaxResult;
//import com.qujia.coupon.domain.CouponInfo;
import com.qujia.station.domain.CouponActivity;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

/**
 * @Auther: LogicQin
 * @Date: 2023/8/4 11:49
 * @Description:
 */
@Repository
public interface CouponActivityMapper {

    public void addCouponActivity(CouponActivity couponActivity);

    public void deleteCouponActivityById(String id);

    public void deleteCouponActivityCountById(String id);


//    public  List<CouponInfo> amtForList(List<String> idList);


//    public  int  addMoonCountAndDayCount(CouponInfo couponInfo);



    public  void updateCouponActivity(CouponActivity couponActivity);

    public  CouponActivity getCouponActivityById(String id);

    public List<CouponActivity> getAllCouponActivities(CouponActivity couponActivity);

    public  void updateActivityStatus(Map<String, Object> params);

    public void insertCouponActivityRelaIssue(Map<String, String> paramMap);

    public void insertCouponActivityLadder(Map<String, String> paramMap);

    public void deleteCouponActivityRelaById(String activityId);

    public void deleteCouponActivityLadder(String activityId);

    public int batchDeleteCouponActivities(List<String> idList);
    // 根据活动 ID 查询对应的 issue_id 列表
    public  List<String> getIssueIdsByActivityId(String activityId);

    // 根据活动 ID 查询对应的 CouponInfo 列表
//    public  List<CouponInfo> getCouponIdsByActivityId(String activityId);

    // 根据活动 ID 查询对应的 Ladder 列表
    public  List<Map<String, Object>> getIssueLadderByActivityId(String activityId);

    public  List<String> checkCouponActivity(Map<String, Object> param);

    public List<String> checkCouponActivityOnLabel(Map<String, Object> param);

    public String checkLabelCouponActivity(Map<String, Object> param);

    public String checkThresholdCouponActivity(Map<String, Object> param);

    public String getSuperGrow(Map<String, Object> param);

    public String getGrow(Map<String, Object> param);

    public  Map<String,Object> getActivityAllByActivityId(String activityId);

    BigDecimal getThresholdAmtByActivityIdAndAmt(@Param("activityId") String activityId, @Param("receivedAmt") BigDecimal receivedAmt);


    List<String> getIssueIdsByThresholdAmt(@Param("activityId") String activityId, @Param("thresholdAmt") BigDecimal thresholdAmt);

}
